package project.menu.mastermenu;

import java.util.ArrayList;

import project.controllers.Controller;
import project.controllers.Helper;
import project.menu.IMenu;
import project.menu.IMenuItem;

public class MasterByOrder implements IMenuItem {
	private static final String name = "Get master by order";
	private static final String METHOD_NAME = "getMasterByOrder";
	private final Integer id = 2;
	private static IMenu submenu;
	private Controller controller = Controller.getInstance();

	public Integer getId() {
		return id;
	}

	public ArrayList<String> action() {
		// getmasterbyorder
		String numberOrder = controller.getNumberOrder().toString();
		return Helper.setParametrs(METHOD_NAME, numberOrder);

	}

	public String getNameItem() {

		return name;
	}

	public void setSubmenu(IMenu menu) {
		submenu = menu;
	}

	public IMenu getMenu() {
		return submenu;
	}
}
